package com.example.demo.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

@TableName("record")
@ApiModel("记录类")
public class Record {
    @TableId(value = "record_id")
    @ApiModelProperty("记录id")
    private int id;
    @TableField("user_id")
    @ApiModelProperty("用户id")
    private int uid;
    @TableField("record_type")
    @ApiModelProperty("练习类型")
    private int type;
    @TableField("question_id")
    @ApiModelProperty("题目id")
    private int qid;
    @TableField("record_result")
    @ApiModelProperty("通过情况")
    private int res;

    public Record() {
    }

    public Record(int id, int uid, int type, int qid, int res) {
        this.id = id;
        this.uid = uid;
        this.type = type;
        this.qid = qid;
        this.res = res;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public int getUid() {
        return uid;
    }

    public void setUid(int uid) {
        this.uid = uid;
    }

    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }

    public int getQid() {
        return qid;
    }

    public void setQid(int qid) {
        this.qid = qid;
    }

    public int getRes() {
        return res;
    }

    public void setRes(int res) {
        this.res = res;
    }

    @Override
    public String toString() {
        return "Record{" +
                "id=" + id +
                ", uid=" + uid +
                ", type=" + type +
                ", qid=" + qid +
                ", res=" + res +
                '}';
    }
}
